<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="renderer" content="webkit">

    <title>网站管理系统</title>

    <!--[if lt IE 8]>
    <meta http-equiv="refresh" content="0;ie.html" />
    <![endif]-->

    <link rel="shortcut icon" href="/favicon.ico"> <link href="/public/admin/css/bootstrap.min.css?v=3.3.5" rel="stylesheet">
    <link href="/public/admin/css/font-awesome.min.css?v=4.4.0" rel="stylesheet">
    <link href="/public/admin/css/plugins/iCheck/custom.css" rel="stylesheet">
    <link href="/public/admin/css/animate.css" rel="stylesheet">
    <link href="/public/admin/css/style.css?v=4.0.0" rel="stylesheet">
    <link href="/public/admin/css/ourstyle.css?v=4.0.0" rel="stylesheet">

    <script src="/public/admin/js/jquery.min.js?v=2.1.4"></script>
    <script src="/public/admin/js/bootstrap.min.js?v=3.3.5"></script>
    <script src="/public/admin/js/myFormValidate.js"></script>
    <script src="/public/admin/js/common.js"></script>
    <script src="/public/admin/js/myAjax.js"></script>
    <script src="/public/admin/js/plugins/layer/layer.min.js"></script>

        <!-- 全局js -->
    <!-- 自定义js -->
    <script src="/public/admin/js/content.js?v=1.0.0"></script>
    <!-- jQuery Validation plugin javascript-->
    <script src="/public/admin/js/plugins/validate/jquery.validate.min.js"></script>
    <script src="/public/admin/js/plugins/validate/messages_zh.min.js"></script>
    
    <script src="/public/admin/js/demo/form-validate-demo.js"></script>

    <script src="/public/admin/plugins/ckfinder/ckfinder.js"></script>
    <script src="/public/admin/js/article.js"></script> 
    <!-- iCheck -->
    <script src="/public/admin/js/plugins/iCheck/icheck.min.js"></script>
</head>

<body class="gray-bg">
    <div class="wrapper wrapper-content">
        
        <div class="row">
            <div class="col-sm-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <ul class="nav nav-tabs">
                            <li class="active"><a data-toggle="tab" href="#tab-1"> SEO优化</a></li>
                        </ul>
                    </div>
                    <div class="ibox-content" style="border-top:none;">
                        <div class="row">
                            <div class="tab-content">
                                <div id="tab-1" class="tab-pane active">
                                    <form class="form-horizontal">
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label">生成sitemap</label>
                                            <div class="col-sm-8"><button class="btn btn-primary" onclick="makesitemap()" type="button">生成sitemap</button><span style="float:left;line-height:40px;"></span></div>
                                        </div>
                                    </form>
                                <hr/>
                                    <form class="form-horizontal">
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label">自动推送百度收录</label>
                                            <div class="col-sm-8"></div>
                                        </div>
                                    </form>
                                            <form action="" method="post" id="tokenForm" class="form-horizontal">
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label">Token：</label>
                                            <div class="col-sm-4">
                                                <input class="form-control" name="token" type="text" placeholder="请填写百度Token" value="{$one.value}">
                                                <input type="hidden" name="inc_type" value="baidu_token">
                                            </div>
                                            <div class="col-sm-2">
                                                <button class="btn btn-primary" onclick="ajax_submit_form('tokenForm','{:url('Other/saveToken')}')" type="button">保存Token</button>
                                            </div>
                                        </div>
                                            </form>

                                            <form action="" method="post" id="pushForm" class="form-horizontal">
                                        <div class="form-group">
                                            <label class="col-sm-2 control-label"></label>
                                            <div class="col-sm-4">
                                                <span style="float:left;line-height:40px;">主动推送最近 </span>
                                                <input class="form-control" style="width:100px;float:left;margin:0 10px;" name="time" type="text" placeholder="1" value="1"><span style="float:left;line-height:40px;"> 天内容（文章）到百度</span>
                                            </div>
                                            <div class="col-sm-2">
                                                <button class="btn btn-primary" onclick="ajax_submit_form('pushForm','{:url('Other/pushCon')}')" type="button">推送</button>
                                            </div>
                                        </div>
                                            </form>
                                </div>


                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>  


<script>
    $(document).ready(function () {
        $('.i-checks').iCheck({
            checkboxClass: 'icheckbox_square-green',
            radioClass: 'iradio_square-green',
        });
    });

    function makesitemap(){
        $.ajax({
            url:"{:url('Other/sitemap')}",
            dataType:'json',
            type:'post',
            success:function(data){
                layer.msg(data.message);
            }
        })
    }
</script>
</body>
</html>
